<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>vue2内容渲染指令</title>
    <script src="https://cdn.jsdelivr.net/npm/vue@2.7.8"></script>
</head>
<body>
    <div id="app">
        <p v-text = "name"></p>
        <p v-text = "gender"></p>

        <hr>
        <p> 姓名：{{ name }}</p>
        <p>性别：{{ gender }}</p>

        <hr>

        <div v-text = "info"></div>
        <div>{{ info }}</div>
        <div v-html="info"></div>
    </div>
    <script>
        const vm = new Vue({
            el:"#app",
            data :{
                name:"张山",
                gender:"男生",
                info : "<h4 style = 'color:red; font-weight = bold;'> 学习vue第一步</h4>"
            },
        });
    </script>
</body>
</html>